package com.supplychain.scm.core.task.bean.exporttask;


import com.supplychain.scm.core.basis.enums.ProductInfoEnum;
import com.supplychain.scm.core.task.constants.ExcelConstants;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.util.List;

/**
 * @author liyang
 * @version 1.0.0
 * @ClassName TaskExport
 * @Description 导出任务入参
 * @createTime 10:24:00 2023/04/26
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class TaskExport implements Serializable {

    private static final long serialVersionUID = -8264477689071924045L;
    /**
     * 检索条件(JSON串)
     */
    private String searchParameter;
    /**
     * 自定义导出表头
     */
    private List<ExcelHeader> exportedFieldsParameter;
    /**
     * sheet名称
     */
    @NotBlank
    private String sheetName;
    /**
     * 文件存储路径
     */
    @NotNull
    private ProductInfoEnum productInfoEnum;
    /**
     * 最大导出数量
     */
    private long maxExportCount = ExcelConstants.MAX_COUNT;
    /**
     * 默认单批次导出条数
     */
    private int pageSize = ExcelConstants.EXPORT_BATCH_COUNT;
}
